PROJECT SUMMARY It is now well-accepted that lowering community viral load through scale-up of antiretroviral therapy (ART) can reduce HIV transmission among people who use drugs. However, achieving durable viral suppression among patients with substance use disorders is a major challenge for clinical providers and health systems. Patients with substance use disorders are continuously at risk for relapse and other disruptive life events. This can lead to frequent lapses in antiretroviral treatment and subsequent viral rebound, which increases the risk of health problems related to HIV and the risk of transmitting HIV to others. This project addresses the problem of lapses in antiretroviral treatment by testing the effectiveness of an innovative mobile health (mHealth) system designed to support people living with HIV and substance use disorders who are receiving HIV care. The mHealth intervention, called A-CHESS, is an evidence-based smartphone application previously shown to reduce substance use and improve retention in addiction treatment by improving social connectedness, intrinsic motivation and coping competence. In this 2-stage, crossover clinical trial, we will provide smartphones running the A-CHESS application to 150 HIV-positive patients who have a past-year history of alcohol, opioid, or stimulant use disorder. In the first phase, participants will use the A-CHESS application to report data in real time describing their drug use, mood, social support, and other factors during a 6-month ecologic momentary assessment (EMA) study. These data will be used to develop and validate a predictive model of treatment non-adherence in this population. After 6 months, all patients will cross over to the second study phase, during which the full, multi-component, tailored mHealth intervention will be delivered using the A-CHESS platform. Simultaneously, data captured by A-CHESS describing participants' risk of treatment lapse will be communicated to patient's providers and clinical support staff, allowing timely and focused support interventions. The effectiveness of the intervention for improving the rate of viral suppression will be assessed using a mixed effects logistic regression model. This project has the potential for high impact because it identifies the critical time-varying determinants of lapses in HIV care for substance using patients, and translates these diverse inputs into actionable, patient-specific alerts to clinical providers.